#!/bin/bash
#set -x
#******************************************************************************
# @file    : antd-init.sh
# @author  : wangyubin
# @date    : 2020-10-07 13:03:48
#
# @brief   : antd init script
# history  : init
#******************************************************************************

antd_init_link=`which antd-init`
real_antd_init=`readlink ${antd_init_link}`
source_dir=`dirname ${real_antd_init}`
echo "antd init DIR:", ${source_dir}

# logo
cp -f ${source_dir}/assets/logo.svg ./public

echo "logo init finished!"

# favicon
cp -f ${source_dir}/assets/favicon.ico ./public

echo "favicon init finished!"

# components
cp -rf ${source_dir}/components/UploadFile ./src/components
cp -rf ${source_dir}/components/UploadImage ./src/components

cp -rf ${source_dir}/services/upload.ts ./src/services
cp -rf ${source_dir}/services/utils.ts ./src/services

echo "components init finished!"
